<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>资料详情</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" href="/static/wx/lib/sui/sm.min.css">
    <link rel="stylesheet" href="/static/wx/lib/sui/sm-extend.min.css">
    <link rel="stylesheet" href="/static/wx/css/reset.css">
    <link rel="stylesheet" href="/static/wx/css/main.css">
    <link rel="stylesheet" href="/static/wx/css/public_main.css">
</head>

<body>
    <div class="page-group">
        <div class="page page-current" id="reject_edit">
            <!-- 主内容 -->
            <div class="content">
                <div class="item-card" style="padding:.5rem 0">
                    <div class="item-card-header">状态：驳回修改</div>
                    <div class="item-card-content">
                        <div class="item-card-content-item">
                            录入时间：{$res.created_at}
                        </div>
                    </div>
                </div>



                {if(isset($data['join_price']))}
                <div class="item-card">
                    <div class="item-card-header">
                        <div>参与竞价</div>
                        <div class="">
                            <a href="{:url('Insurant/return_price',['p_id'=>$p_id])}"><img src="/static/wx/imgs/img/xiugai.png" width="20"/></a>
                        </div>
                    </div>
                    <div class="item-card-content">
                        <div class="item-card-content-item">
                            本人是否参与竞价拍卖：{if(isset($res.is_join))}{if($res.is_join == 1)}参与{elseif($res.is_join == 2)}不参与{/if}{/if}
                        </div>
                        <div class="item-card-content-item">
                            参与竞价拍卖需缴纳保证金：{if(isset($res.is_join))}{if($res.is_promise == 1)}申请缴纳保证金{elseif($res.is_promise == 2)}缴纳保证金{/if}{/if}
                        </div>
                        <div class="item-card-content-item">
                            优先回购价格（总价）：{$res.back_price |default = ''} 元
                        </div>
                    </div>

                    <div class="edit-content">
                        {foreach($data['join_price'] as $k =>$v)}
                        {if($v)}
                        <p>修改内容：{$v}</p>
                        {/if}
                        {/foreach}
                    </div>
                </div>
                {/if}

                {if(isset($data['look_goods_info']))}
                <div class="item-card">
                    <div class="item-card-header">
                        <div>看货信息</div>
                        <div class="">
                            <a href="{:url('Insurant/return_goods_info',['p_id'=>$p_id])}"><img src="/static/wx/imgs/img/xiugai.png" width="20"/></a>
                        </div>
                    </div>
                    <div class="item-card-content">
                        <div class="item-card-content-item">
                            看货要求：{if($res.look_type == 1)}预约联系{elseif($res.look_type ==2)}随时看货{elseif($res.look_type ==3)}交纳保证金后看货{/if}
                        </div>
                        <div class="item-card-content-item">
                            看货地址：{$res.province}{$res.city}{$res.town}{$res.address_detail}
                        </div>
                        <div class="item-card-content-item">
                            联系人：{$res.linkman |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            手机号：{$res.phone |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            备用联系人：{$res.second_phone |default = ''}
                        </div>
                    </div>
                    <div class="edit-content">
                        {foreach($data['look_goods_info'] as $k =>$v)}
                        {if($v)}
                        <p>修改内容：{$v}</p>
                        {/if}
                        {/foreach}
                    </div>
                </div>
                {/if}


                {if(isset($data['bol_info']))}
                <div class="item-card">
                    <div class="item-card-header">
                        <div>提货信息</div>
                        <div class="">
                            <a href="{:url('Insurant/return_bol',['p_id'=>$p_id])}"><img src="/static/wx/imgs/img/xiugai.png" width="20"/></a>
                        </div>
                    </div>
                    <div class="item-card-content">
                        <div class="item-card-content-item">
                            提货是否需要支付其他费用：{if(isset($res.is_pay))}{if($res.is_pay == 1)}是{elseif($res.is_pay == 2)}否{/if}{/if}
                        </div>
                        <div class="item-card-content-item">
                            {$res.pay_result}
                        </div>
                        <div class="item-card-content-item">
                            提货详细说明：{$res.bol_info}
                        </div>
                        <div class="item-card-content-item" style="display:flex">
                            <div> 看货地址：</div>
                            <div>
                                <div>{$res.bol_province}{$res.bol_city}{$res.bol_town}</div>
                                <div>{$res.bol_address_detail}</div>
                            </div>
                        </div>
                        <div class="item-card-content-item">
                            联系人：{$res.bol_linkman}
                        </div>
                        <div class="item-card-content-item">
                            手机号：{$res.bol_phone}
                        </div>
                        <div class="item-card-content-item">
                            提货时限：竞价拍卖后{$res.bol_days |default = ''} 天内提货
                        </div>
                    <div class="edit-content">
                        {foreach($data['bol_info'] as $k =>$v)}
                        {if($v)}
                        <p>修改内容：{$v}</p>
                        {/if}
                        {/foreach}
                    </div>
                </div>
                {/if}





                {if(isset($data['receive_money']) && !empty($data['receive_money']))}
                <div class="item-card">
                    <div class="item-card-header">
                        <div>收款信息</div>
                        <div class="">
                            <a href="{:url('Insurant/return_money',['p_id'=>$p_id])}"><img src="/static/wx/imgs/img/xiugai.png" width="20"/></a>
                        </div>
                    </div>
                    <div class="item-card-content">
                        <div class="item-card-content-item">
                            您的收款名称：{$res.pay_name |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            开户银行：{$res.bank_name |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            账号：{$res.card_num |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            税号：{$res.tax_num |default = ''}
                        </div>
                        <div class="item-card-content-item">
                            地址：{$res.company_address |default = ''}
                        </div>
                    </div>
                    <div class="edit-content">
                        {foreach($data['receive_money'] as $k =>$v)}
                        {if($v)}
                        <p>修改内容：{$v}</p>
                        {/if}
                        {/foreach}
                    </div>
                </div>
                {/if}




                {if(isset($data['auth_report']))}
                 <div class="item-card">
                     <div class="item-card-header">
                         <div>委托书</div>
                         <div class="">
                             <a href="{:url('Insurant/return_report',['p_id'=>$p_id])}"><img src="/static/wx/imgs/img/xiugai.png" width="20"/></a>
                         </div>
                     </div>
                    <div class="item-card-content">
                        <div class="item-card-content-item" style="display:flex;align-items:center;">
                            <div>委托书：</div>
                                {if isset($res['entrust_url'])}
                                {foreach($res['entrust_url'] as $v)}
                                <div class="pre-view">
                                    <img src="{$v}" style="width: 2.5rem;height: 2.5rem">
                                </div>
                                {/foreach}
                                {/if}
                            </div>
                    </div>
                     <div class="edit-content">
                         {foreach($data['auth_report'] as $k =>$v)}
                         {if($v)}
                         <p>修改内容：{$v}</p>
                         {/if}
                         {/foreach}
                     </div>
                </div>
                {/if}

                <div class="btn-box">
                        <div class="my-btn" >
                            <input type="hidden" id="i_id" value="{$res.i_id}">
                            <span class="active" id="submit">修改完提交</span>
                        </div>
                </div>
                <p class="text-c size-m" style="margin:0 2rem 1rem 2rem;">只有将要修改的内容全部修改完，再提交，否则审核不通过</p>
            </div>
        </div>
    </div>
    <script type='text/javascript' src='/static/wx/lib/sui/zepto.min.js' charset='utf-8'></script>
    <script type='text/javascript' src='/static/wx/lib/sui/sm.min.js' charset='utf-8'></script>
    <script type='text/javascript' src='/static/wx/lib/sui/sm-extend.min.js' charset='utf-8'></script>
    <script>
        $('#submit').on('touchend',function() {
            var i_id = $('#i_id').val();
            $.confirm('已全部修改完递交资料','',
                function () {
                    $.ajax({
                        url:'/wx/insurant/return_save',
                        type:'post',
                        dataType:'json',
                        data:{
                            'i_id':i_id,
                        },
                        success:function (data) {
                            if(data.code ==200){
                                $.alert('修改成功');
                                window.location.href = '/wx/insurant/historyInfo';
                            }else{
                                $.alert(data.msg);
                            }
                        }
                    });
                },
                function () {
                    return false;
                }
            );
        });


        // var vm = new Vue({
        //     el: '#reject_edit',
        //     data: {
        //         phone: "18638779089",
        //         password: "123478",
        //         encode: true,
        //     },
        //     methods: {
        //         login: function () {
        //             console.log('login in ing')
        //         },
        //         removePhone: function () {
        //             this.phone = '';
        //             this.showClose = false
        //         },
        //         doEncode: function () {
        //             this.encode = !this.encode
        //         },
        //     },
        // })
    </script>
</body>

</html>